home *** CD-ROM | disk | FTP | other *** search
/ CD ROM Paradise Collection 4 / CD ROM Paradise Collection 4 1995 Nov.iso / edit / e4dv203.zip / E4D.DOC < prev    next >
Text File  |  1994-10-10  |  6KB  |  175 lines

  1. ************************************************************************
  2. E4-Deluxe Documentation
  3. (C) Copyright Neil Faulks 1993. All Rights Reserved.
  4. Created 15th July 1993, Last Modified 2nd October 1994
  5. ************************************************************************
  6.  
  7. E4-Deluxe is an enhanced version of E4 that provides pull-down menus. It 
  8. is a separate product because
  9.  
  10. 1) Pull-Down Menus are not part of the E4 Design Philosophy
  11.  
  12. 2) The menu system adds quite a lot of code to the E4 executable.
  13.  
  14. This file describes the E4-Deluxe menu system.
  15.  
  16. Activating the Menus
  17.  
  18.  E4-Deluxe has a built-in set of menus that are used by default. 
  19.  However, the menu bar will not appear unless a key in the keymap 
  20.  file (E4KEYS) is assigned the special keyname MENU. The supplied 
  21.  E4KEYS file has an entry:
  22.  
  23.      F10    MENU
  24.  
  25.  Which causes the menu bar to be displayed on start up, and 
  26.  allows the user access the menus by pressing F10.
  27.  
  28. Keymap Files
  29.  
  30.  Both E4 and E4-Deluxe use the /= command line switch to select a 
  31.  keymap file other that the default E4KEYS. For example
  32.  
  33.      E4 /=TEST
  34.  
  35.  would cause E4 to look for a keymap file called TEST.E4K
  36.  
  37.  However in E4-Deluxe the same option also selects a menu file, 
  38.  to be used instead of the built-in menu set. In the example 
  39.  above (but using E4D) the menu file would have the name TEST.E4U
  40.  
  41.  There is, therefore, a close relationship between a keymap file 
  42.  and a menu file with the same name.
  43.  
  44.  As mentioned in the section above, the keymap file must assign 
  45.  the special MENU function to at least one key to make the menu 
  46.  bar appear. The MENU function can also be used to assign a 
  47.  particular pull-down menu to a key. For example you could make 
  48.  ALT-F open the File menu by using the following entry in the 
  49.  keymap file:
  50.  
  51.      @F    MENU F
  52.  
  53.  This requires that the "F" in "File" is highlit on the menu bar.
  54.  
  55.  The keymap file can be divided into sections, so that some key 
  56.  assignments are made only if E4-Deluxe is used, whilst others 
  57.  apply only to E4. Special headers, [menus] and [nomenus], are 
  58.  used to separate the sections:
  59.  
  60.      ... Entries affecting both versions ...
  61.  
  62.      [menus]
  63.  
  64.      ... Entries affecting only E4-Deluxe ...
  65.      
  66.      [nomenus]
  67.  
  68.      ... Entries affecting only normal E4 ...
  69.  
  70.  Several of the supplied keymap files use this technique. The 
  71.  text between the headers can be any normal keymap file entries 
  72.  including key and variable assignments and comments.
  73.  
  74. Menu Files
  75.  
  76.  A menu file is a text file with the extension .E4U (E4 
  77.  User-defined menu). Although a menu file appears to be fairly 
  78.  free-format it is, in fact, subject to several restrictions, 
  79.  which are described in the sections below.
  80.  
  81.  The E4 menu system works by assigning a sequence of key presses 
  82.  to a menu item, similar to the way keys are assigned different 
  83.  functions in the E4KEYS file.
  84.  
  85. Menu File Format
  86.  
  87.  <Top Menu>
  88.  
  89.  <Menu 1, Item 1>    <Keys>    [<Description>]
  90.  <Menu 1, Item 2>    <Keys>    [<Description>]
  91.  <Menu 1, Item n>    <Keys>    [<Description>]
  92.  
  93.  <Menu 2, Item 1>    <Keys>    [<Description>]
  94.  <Menu 2, Item 2>    <Keys>    [<Description>]
  95.  <Menu 2, Item n>    <Keys>    [<Description>]
  96.  
  97.  The top menu must be the first line of the file.
  98.  
  99.  One or more blank lines are used to separate menus, but there 
  100.  must be no blank lines between menu items.
  101.  
  102.  The fields <Item> <Keys> <Description> must be separated by a 
  103.  SINGLE tab character. To get the menu to look nice when editing 
  104.  set the tab size to something large, say 20.
  105.  
  106.  Tilde characters (~) are used to highlight a (following) letter 
  107.  in the Top Menu or a menu Item. Highlighted letter are used so 
  108.  that the user can select menu items by pressing the 
  109.  corresponding key. The case of the letter is not important.
  110.  
  111.  <Item> Field
  112.      
  113.      The item field is the text that is displayed on the 
  114.      menu. A tilde preceding a letter causes it to be highlit 
  115.      when the menu is displayed. The user may then select the 
  116.      menu item by pressing the key coresponding to the 
  117.      highlit letter.
  118.      
  119.  <Keys> Field
  120.      
  121.      The keys field is a list of keys, separated by spaces, 
  122.      that are to be pressed when the user selects that menu 
  123.      item. The Keys field can consist of two sub-fields, 
  124.      separated by a semicolon. The first part is what is 
  125.      displayed on the menu, the second part is the key list. 
  126.      Either sub-field may be empty.
  127.      
  128.      The list of keys to be pressed may start with an 
  129.      exclamation sign (!), in which case the keys listed are 
  130.      subject to any key mappings (key assigments) in effect. 
  131.      Otherwise the keys are not subject to re-assignment and 
  132.      always have their normal E4 meanings.
  133.  
  134.      For example this entry is not affect by the keymap file, 
  135.      ^E would have to be defined as a macro:
  136.  
  137.          Menu text    ^E    Item Description
  138.  
  139.      This entry is affected by the keymap file (^E could be a 
  140.      macro or a key assignment):
  141.      
  142.          Menu text    !^E    Item Description
  143.          
  144.      To avois the ! appearing in the display use a semicolon 
  145.      to separate a list of keys that are displayed from those 
  146.      that are actually pressed:
  147.          
  148.          Menu text    ^E;!^E    Item Description
  149.      
  150.  <Description> Field
  151.      
  152.      The description is an optional string that is displayed 
  153.      on the message line when the user places the selector 
  154.      bar over that menu item.
  155.  
  156. Sample Menu File
  157.  
  158.  ~File ~Edit ~Special
  159.  
  160.  ~New    @B @N    Create a New file
  161.  ~Open    @L    Open (Load) a file on disk
  162.  ~Save    @S @S    Save current buffer to file
  163.  |E~xit    @Q    Quit the editor
  164.  
  165.  Cu~t    @X    Cut block to clipboard
  166.  ~Copy    @C    Copy block to clipboard
  167.  ~Paste    @V    Insert contents of clipboard at cursor position
  168.  ~Mark    @A    Mark a block to be Cut or Copied
  169.  
  170.  Test ^A ~Macro    ^A    Invoke ^A macro
  171.  Test ^A ~Keymap    !^A    Invoke ^A via keymap file
  172.  
  173.  Several menu files are supplied with the editor and these should 
  174.  be examined for more examples.
  175.